import { request } from "@ruifox-cms/utils";
// 检查用户状态 当前是否绑定企业
export function checkUser(params) {
  return request({
    
    url: "/bidding/user/check",
    method: "get",
    params,
  });
}
//用户绑定企业
export function insertEnterprise(data) {
  return request({
    
    url: "/bidding/enterprise/insert",
    method: "post",
    data,
  });
}
//用户修改企业
export function updateEnterprise(data) {
  return request({
    
    url: "/bidding/enterprise/update",
    method: "post",
    data,
  });
}
//根据企业id查询当前企业信息  
export function selectEnterprise(params) {
  return request({
    
    url: "/bidding/enterprise/select",
    method: "get",
    params,
  });
} 
//查询用户所属企业
export function selectUserEntEnterprise(params) {
  return request({
    
    url: "/bidding/enterprise/selectUserEnt",
    method: "get",
    params,
  });
} 
//用户加入企业
export function applyToJoinUser(data) {
  return request({
    
    url: "/bidding/user/applyToJoin",
    method: "post",
    data,
  });
} 
//判断企业信用代码是否存在 
export function existEnterprise(params) {
  return request({
    
    url: "/bidding/enterprise/exist",
    method: "get",
    params,
  });
} 
// 分页查询公告（供应商）
export function selectPageProvider(params) {
  return request({
    
    url: "/bidding/notice/provider/selectPage",
    method: "get",
    params,
  });
}
//根据id查询公告详情
export function selectFrontNotice(params) {
  return request({
    
    url: "/bidding/notice/selectFront",
    method: "get",
    params,
  });
}
//查询预设资质证书 
export function selectPrefixListCertificate(params) {
  return request({
    
    url: "/bidding/certificate/selectPrefixList",
    method: "get",
    params,
  });
}
//供应商提交资质
export function insertCertificate(data) {
  return request({
    
    url: "/bidding/certificate/insert",
    method: "post",
    data,
  });
}
//供应商删除资质
export function deleteCertificate(params) {
  return request({
    
    url: "/bidding/certificate/delete",
    method: "post",
    params,
  });
}
//根据企业id分页查询证书 
export function certificateBidding(params) {
  return request({
    
    url: "/bidding/certificate",
    method: "get",
    params,
  });
}
//供应商报名 
export function insertParticipateApplication(data) {
  return request({
    
    url: "/bidding/participateApplication/insert",
    method: "post",
    data,
  });
}
//取消报名 
export function cancelApplicationParticipateApplication(data) {
  return request({
    
    url: "/bidding/participateApplication/cancelApplication",
    method: "post",
    data,
  });
}
//查询用户当前企业是否已经报名 
export function hasApplyParticipateApplication(params) {
  return request({
    
    url: "/bidding/participateApplication/hasApply",
    method: "get",
    params,
  });
}

//查看投标记录
export function selectPageParticipateApplication(params) {
  return request({
    
    url: "/bidding/participateApplication/selectPage",
    method: "get",
    params,
  });
}
//检查报名凭证
export function checkCertificateParticipateApplication(params) {
  return request({
    
    url: "/bidding/participateApplication/checkCertificate",
    method: "get",
    params,
  });
}